//import org.springframework.boot.autoconfigure.EnableAutoConfiguration;
//import org.springframework.boot.autoconfigure.jdbc.DataSourceAutoConfiguration;
//import org.springframework.boot.autoconfigure.orm.jpa.HibernateJpaAutoConfiguration;

/*package com.kyhd.toutiao.server;

import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.EnableAutoConfiguration;
import org.springframework.boot.context.embedded.EmbeddedServletContainerFactory;
import org.springframework.boot.context.embedded.jetty.JettyEmbeddedServletContainerFactory;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import org.springframework.context.annotation.Import;
import org.springframework.scheduling.annotation.EnableScheduling;

import com.kyhd.toutiao.config.JPAConfiguration;
import com.kyhd.toutiao.config.QQWryConfiguration;
import com.kyhd.toutiao.config.RedisHaConfiguration;
import com.kyhd.toutiao.config.ServiceConfiguration;
import com.kyhd.toutiao.util.SchedulingUtil;

@EnableScheduling 
@EnableAutoConfiguration
//@EnableAutoConfiguration(exclude={DataSourceAutoConfiguration.class,HibernateJpaAutoConfiguration.class})
@Configuration
@Import({ ServiceConfiguration.class, JPAConfiguration.class, 
	RedisHaConfiguration.class,SchedulingUtil.class
	,QQWryConfiguration.class
//	,Swagger2.class
	})
//@ComponentScan(basePackages = { "com.kyhd.toutiao.controller" }, useDefaultFilters = false, //
//        includeFilters = { @ComponentScan.Filter(type = FilterType.ASSIGNABLE_TYPE, value = {
//                ToutiaoExceptionHandler.class,
//        		DemoController.class,NewsController.class,UserController.class,TaskController.class,
//        		MentoringController.class,UcCallbackController.class,ShareController.class,
//        		UserMessageController.class,CashController.class
//                }) })
//
//@ServletComponentScan(basePackages = { "com.kyhd.toutiao.controller.filter" })
public class ToutiaoSchedule {

	public static int port = 9888;

	@Bean
	// https://wiki.eclipse.org/Jetty/Howto/High_Load#Thread_Pool
	public EmbeddedServletContainerFactory servletContainer() {
		JettyEmbeddedServletContainerFactory factory = new JettyEmbeddedServletContainerFactory();
		factory.setPort(port);
		// factory.addServerCustomizers();

		return factory;
	}

	public static void main(String[] args) throws Exception {
		try {
			String portNumString = System.getProperty("port");
			if (portNumString != null) {
				port = Integer.parseInt(portNumString.trim());
			}
		} catch (Exception e) {
		}

		SpringApplication.run(ToutiaoSchedule.class, args);
	}

}

*/